Welcome Guest | Sign in | Register
Windows Controls - DotNet Programming Interview Questions and Answers | LucentBlackBoard | LucentBlackBoard.com

Home > Technical Interviews > Computer Science & Engineering > DotNet Programming > Windows Controls Questions and Answers

51. Can you add more than one item simultaneously in the ListBox control?

Yes, You can add more than one item simultaneously in the ListBox control by using the AddRange() method.

52. What is the difference between a MenuStrip control and a ContextMenuStrip control?

The difference between a MenuStrip control and a ContextMenuStrip control is that a MenuStrip control is associated with the Windows Form; whereas, a ContextMenuStrip control is associated with a control, which is added to the Windows Form.

53. What are the values that can be assigned to the DialogResult property of a Button control?

The DialogResult property of a Button control can be assigned a value from the DialogResult enumerations, which are as follows:
• Abort-Returns Abort
• Cancel-Returns Cancel
• Ignore-Returns Ignore
• No-Returns No
• None-Nothing is returned from the dialog box
• OK-Returns OK
• Retry-Returns Retry
• Yes-Returns Yes

54. Why do you require user-defined controls?

User-defined controls are particularly useful in situations where you need to enhance the functionality of an existing control.

55. Is it possible to enter more than one line in a TextBox control?

Yes, it is possible to enter more than one line in a TextBox control. To do this, you need to set the Multilineproperty of the TextBox control to True. You can set this property at design time as well as runtime. The syntax to set this property at runtime is as follows:

Textbox1.Multiline = true;




Partner Sites
LucentBlackBoard.com                  SoftLucent.com                  LucentJobs.com
All rights reserved © 2012-2015 SoftLucent.